import IScript from "../IScript";
import root from "../../types/msg"
import {move as instance } from "../../msg/msg"
import MsgSend from "../../msg/MsgSend";

export  class S2C_SyncPositionScript implements IScript {

    private static  _instance = new S2C_SyncPositionScript()
    public static get instance(){
        return S2C_SyncPositionScript._instance;
    }
    private constructor(){}

    excute(obj: any) {
        this.handle(obj )
    }

    handle(msg: root.move.S2C_SyncPosition) {
        let resp:root.move.IC2S_SyncPosition = {
            x:3,
            y:3,
            str:"前端回复"
        }
        MsgSend.send(instance.C2S_SyncPosition,resp)
    }
}

export default S2C_SyncPositionScript.instance
